package cn.zymall.common.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.util.Date;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;

@Data
@EqualsAndHashCode(callSuper = true)
@AllArgsConstructor
@NoArgsConstructor
@TableName(value = "user_coupon")
public class UserCoupon extends BaseEntity implements Serializable {
    /**
     * 用户领劵编号
     */
    @TableId(value = "USER_COUPON_ID", type = IdType.AUTO)
    private Integer userCouponId;

    /**
     * 用户编号
     */
    @TableField(value = "USER_ID")
    private Integer userId;

    /**
     * 优惠劵编号
     */
    @TableField(value = "COUPON_ID")
    private Integer couponId;

    /**
     * 领劵时间
     */
    @TableField(value = "RECEIVE_TIME")
    private Date receiveTime;

    /**
     * 状态(已使用，未使用)
     */
    @TableField(value = "STATUS")
    private Byte status;

    /**
     * 使用时间(对应订单id,时间)
     */
    @TableField(value = "USE_TIME")
    private Date useTime;

    /**
     * 对应订单id
     */
    @TableField(value = "ORDER_ID")
    private Date orderId;

    private static final long serialVersionUID = 1L;

    public static final String COL_USER_COUPON_ID = "USER_COUPON_ID";

    public static final String COL_USER_ID = "USER_ID";

    public static final String COL_COUPON_ID = "COUPON_ID";

    public static final String COL_RECEIVE_TIME = "RECEIVE_TIME";

    public static final String COL_STATUS = "STATUS";

    public static final String COL_USE_TIME = "USE_TIME";

    public static final String COL_ORDER_ID = "ORDER_ID";
}
